﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Data;
using System.Data.SqlClient;
using ThongTin;

namespace DuLieu
{
   
     public class Khoa_DL
    {
         KetNoi_DL ketnoi = new KetNoi_DL();
         public DataTable DanhSachKhoa()
     {
         return ketnoi.LayDuLieu("DanhSachKhoa");
     }
         public int ThemKhoa(Khoa_TT KH)
         {
             int Nparameter = 2;
             string[] name = new string[Nparameter];
             object[] value = new object[Nparameter];
             name[0] = "@MaKhoa"; value[0] = KH.MaKhoa;
             name[1] = "@TenKhoa"; value[1] = KH.TenKhoa;
             return ketnoi.CapNhat("ThemKhoa", name, value, Nparameter);
         }
    }
}
